var monitwebstatus = {
  onLoad: function() {
    // initialization code
    this.initialized = true;
    this.strings = document.getElementById("monitwebstatus-strings");
    document.getElementById("contentAreaContextMenu")
            .addEventListener("popupshowing", function(e) { this.showContextMenu(e); }, false);
  },

  showContextMenu: function(event) {
    // show or hide the menuitem based on what the context menu is on
    // see http://kb.mozillazine.org/Adding_items_to_menus
    document.getElementById("context-monitwebstatus").hidden = gContextMenu.onImage;
  },
  onMenuItemCommand: function( e ) 
  {
	var samplePanel = document.getElementById('my-panel');
	samplePanel.label += "X";
  },
  onToolbarButtonCommand: function(e) {
    // just reuse the function above.  you can change this, obviously!
    monitwebstatus.onMenuItemCommand(e);
  }

};
//window.addEventListener("load", function(e) { monitwebstatus.onLoad(e); }, false );

window.addEventListener("load", function(e) { StockWatcher.startup(); }, false);
